﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Text;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;

/// <summary>
/// 依赖注入容器
/// </summary>
public static class ServiceLocator
{
    public static IServiceProvider Instance { get; set; }

    public static T GetService<T>() //where T : class
    {
        return Instance.GetService<T>();
    }
}